Adding file descriptor in template.
[and.git] / 10812 - Beat the spread / 10812.cpp
blobc2d71676abecb21ee306e17e069fc34be8a2aca6
1 #include <iostream>
3 using namespace std;
5 int main(){
6 int n;
7 cin >> n;
8 while (n--){
9 unsigned long long s,d,x,y;
10 cin >> s >> d;
11 if (s < d || (s+d)%2 != 0 || (s-d)%2 != 0){
12 cout << "impossible" << endl;
13 }else{
14 cout << (s+d)/2 << " " << (s-d)/2 << endl;
17 return 0;